package cc.fine.svc.main.service.rel;

import cc.fine.svc.main.bean.po.RelUserVideoFavor;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author wyihe
 * @since 2023-10-25
 */
public interface RelUserVideoFavorService extends IService<RelUserVideoFavor> {

    /**
     * 存储用户的点赞信息
     * userId::list<videoId>
     */
    String Favor_Cache = "favor_cache";

    /**
     * 给视频点赞
     * @param favor
     */
    void favor(RelUserVideoFavor favor);


    /**
     * 取消视频点赞
     * @param favor
     */
    void disFavor(RelUserVideoFavor favor);

    boolean isFavor(String userId, String videoId);
}
